package com.knxhd.enums;

/**
 * Author: tianluhua tianlh@qdcares.cn
 * Date: 2025-07-12 15:17:21
 * Description: 大模型消息类型
 */
public enum Role {

  user,

  system,

  assistant,

  ai,

  function;

  public static Role getRole(String role) {
    for (Role value : Role.values()) {
      if (value.name().equalsIgnoreCase(role)) {
        return value;
      }
    }
    return null;
  }

}
